package pl.SilverSable.Engine.physic;

import com.badlogic.gdx.math.Rectangle;
import com.badlogic.gdx.math.Vector2;


public abstract class GameObject {

	//protected SimpleRectangle body;
	protected Rectangle body;
	protected float angle;
	protected int TypeObject;
	
	public GameObject(int type, SimpleRectangle body){
		TypeObject = type;
		this.body = body.ConvertToRectangle();
	}
	
	public int GetTypeObject(){
		
		return TypeObject;
	}
	public Rectangle GetBodyObject(){
		
		return body;
	}
	
	//Funkcje pomocnicze
	/**
	 * 
	 * @return pozycja postaci w pixelach
	 */
	public Vector2 GetMiddle(){
		
		return new Vector2(body.x + body.width / 2,body.y + body.height / 2);
		
	}	
}
